<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>

    <script src="jquery.js"></script>
    <script>
        $.ajax({
            url:"http://test.hfjava.com/yzm.jsp",
            dataType:"jsonp",
            success:function(data){
                alert(data.code);
            }
        });
    </script>
</head>
<body>

<form id="regform">
    <input type="hidden" name="countryNo" value="86" />
<input placeholder="电话号码" id="phone" name="phone" autocomplete="off" />
<span id="phoneerror"></span>
    <br /><br />
<input placeholder="验证码" id="yzm" />
    <span id="yzmerror"></span>

    <input type="button" value="发送验证码" id="yanzhengmaBtn" disabled />
    <br /><br />
<input placeholder="密码" id="pwd1" name="pwd" title="密码长度为6~16位，数字、字母和符号至少包含两种" />
    <span id="pwderror1"></span>
<br /><br />
<input placeholder="重复密码" id="pwd2" />
    <span id="pwderror2"></span>
<br /><br />
<input type="checkbox" id="agreeCK" /><a href="#">注册协议</a>
<br /><br />
<input type="button" id="submitBtn" value="注册" disabled />
</form>
<script src="reg.js"></script>

</body>
</html>